﻿/// <reference path="jquery-1.3.2-vsdoc.js" />

$(document).ready(function() {

    var dto = new LoanDto("http://localhost:8080/LoanService");
    dto.firstName = "John";
    dto.lastName = "Doe";
    dto.CreateLoan(success, error);

    function success(data, textStatus) {
        alert(data);
    }

    function error(xhr, textStatus, errorThrown) {

        if (typeof console != "undefined") {
            console.error("textStatus: %s, errorThrown: %s", textStatus, errorThrown);
        }
    }
});